\begin{tikzpicture}
    \pgfmathsetmacro{\a}{2.5}
    \pgfmathsetmacro{\h}{4}

    \tkzDefPoints{0/0/h1, \h/0/h2, 0/0.8/a1, \a/0.8/a2}
    \tkzDrawSegments[xianduan={below=0pt}](h1,h2)
    \tkzLabelSegment[above](h1,h2){$h$}
    \tkzDrawSegments[xianduan={below=0pt}](a1,a2)
    \tkzLabelSegment[above](a1,a2){$a$}

    \begin{scope}[xshift=6cm]
        % 1
        \tkzDefPoints{0/0/B, \a/0/C}
        \tkzDrawSegment(B,C)
        \tkzLabelPoints[left](B)
        \tkzLabelPoints[right](C)

        % 2
        \tkzDefLine[mediator,normed](B,C)  \tkzGetPoints{m}{N}
        \tkzDefPointOnLine[pos=3](N,m)  \tkzGetPoint{M}
        \tkzInterLL(B,C)(M,N)  \tkzGetPoint{D}
        \tkzDrawSegment(M,N)
        \tkzMarkRightAngle(M,D,B)
        \tkzLabelPoints[right](M,N)
        \tkzLabelPoints[above right](D)

        % 3
        \tkzInterLC[R,near](M,N)(D,\h)  \tkzGetFirstPoint{A}
        \tkzLabelPoints[left](A)

        % 4
        \tkzDrawSegments(A,B  A,C)
    \end{scope}
\end{tikzpicture}

